#! /bin/bash

# ----------------------------------------------------------------------------
#
# Library.
#
# yqm_leaf@163.com
#
# 05/05/21
#
# ----------------------------------------------------------------------------

gen_log_file () {
    local base_log_filename=$(echo $(date +'%Y_%m_%d_%H_%M_%S_'))
    local suffix=".log"
    for i in {0..50} ; do
        local log_file="${base_log_filename}${i}${suffix}"
        [ -f $log_file ] && continue
        echo $log_file
        break
    done
}
